<?php $this->headLink()->appendStylesheet($this->js('css/jquery.alerts.css'))
->appendStylesheet($this->Css('button.css'))
?>
<?php $this->headStyle()->captureStart()?>
<?php echo $this->render('css/manage-style.css')?>

<?php $this->headStyle()->captureEnd()?>
<?php $this->headScript()
->appendFile($this->js('jquery-ui/ui/jquery.ui.tabs.js'))
->appendFile($this->js('jquery-ui/ui/jquery.ui.draggable.js'))
->appendFile($this->js('jquery-ui/ui/jquery.ui.resizable.js'))
->appendFile($this->js('jquery-ui/ui/jquery.ui.dialog.js'))
->appendFile($this->js('jquery-ui/external/bgiframe/jquery.bgiframe.js'))
->appendFile($this->js('plugins/jquery.alerts.js'))
->appendFile($this->js('plugins/jquery.form.js'))

->captureStart()?>

function modset(id) {
	$.get('<?php echo $this->route('formset')?>',{id:id},function(data){
		$("#setform").html(data);
	});
}



$(document).ready(function(){

	$("#id_kind").live('change',function(){
		var kind = $(this).val();
		$("#temp_div").show()
		$("#temp_id").empty();
		$.getJSON('<?php echo $this->route('getitem')?>/kind/'+kind,function(data){
			$.each(data.items,function(){
				$("#temp_id").append('<option value="'+this.sn+'">'+this.name+'</option>');
			});
		});
	});

	$("#permList .delacl").live('click',function(){
	if(confirm('<?php echo $this->translate('confirm delete')?>')) {
	var d_id = $(this).attr('id').substr(2);
	delacl(d_id); // 刪除權限

	}
});

});


<?php $this->headScript()->captureEnd()?>

<table>
<tr>
<td style="width:500px;vertical-align: top">
<?php echo $this->render("manager/module-list.phtml")?>
</td>
<td style="width:450px;vertical-align: top;">
<div id="setform" style="display:none"></div>
</td>
</tr>
</table>
